#include "common.h"

int main()
{
	pid_t pid;

	pid = fork();
	if(pid < 0)
		err_sys("fork error\n");
	else if(pid == 0)
	{
		//sleep(3);
		printf("child pid : %d\n", getpid());
		printf("child ppid : %d\n", getppid());
		exit(0);
	}
	else
	{
		sleep(3);
		printf("parent pid : %d\n", getpid());
		system("ps -l");
		exit(0);
	}

	return 0;
}
